home *** CD-ROM | disk | FTP | other *** search
Wrap
Text File | 1998-09-30 | 56.1 KB | 1,525 lines
;------------------------------------------------------------------------ ; ; Laplace Installation script ; ; $VER: Laplace-Install 1.6 (29.1.1998) ; ; Script: (C)1996/1997 by A Vision of Paradise ; Installer: (C)1996 ESCOM AG ; written by P!\K ; ;------------------------------------------------------------------------ ;-1- "language definitions" (if (= @language "deutsch") ( ;-1- "deutsch" (set #lhapath-prompt "Lha wird benötigt! Wo befindet es sich?") (set #lhapath-help (cat "Lha wird benötigt, um die Installation durchzuführen. " "Es wurde aber nicht im C: Verzeichnis gefunden!\n" "Es ist der vollständige Pfad anzugeben, an dem es zu finden ist.\n" "\n" @askfile-help ) ) (set #welcome "Willkommen bei der Installation von Laplace.") (set #mode-prompt "") (set #mode-help @askchoice-help) (set #modeupdate-prompt (cat "Welche Aktion willst Du ausführen?\n" "Laplace V%s ist bereits in %s installiert." ) ) (set #modeupdate-help @askchoice-help) (set #mode-update "Laplace aktualisieren") (set #mode-install "Laplace installieren") (set #mode-deinstall "Laplace löschen") (set #share-info (cat "Wenn Dir dieses Programm gefällt, schicke mir bitte eine e-Mail oder Postkarte.\n" "\n" "e-mail:\n" "bstegema@ix.urz.uni-heidelberg.de\n" "\n" "s-mail:\n" "Benjamin Stegemann\n" "Emmertsgrundpassage 1\n" "69126 Heidelberg\n" "Germany" ) ) (set #wrongversion (cat "Dieses Skript benötigt den Installer V42.9 oder höher. " "Er befinded sich im Verzeichnis Laplace/Tools und sollte eigentlich benutzt werden. " "Falls Du ein Tool wie ToolAlias benutzt, kopiere diese Version als Deinen Standartinstaller. " ) ) (set #wrongos (cat "Laplace benötigt OS V39 oder besser.\n" "Du hast V%ld.%ld installiert. Sorry." ) ) (set #wrongmui (cat "Laplace benötigt MUI V13 oder besser.\n" "Du hast V%ld.%ld installiert. Sorry.\n\n" "MUI ist im Aminet erhältlich:\n" "dev/gui/muiXXusr.lha\n" "Wobei XX die Versionsnummer ist." ) ) (set #nomui (cat "Laplace benötigt MUI V13 oder besser.\n" "Zur Zeit ist MUI nicht installiert. Sorry.\n\n" "MUI ist im Aminet erhältlich:\n" "dev/gui/muiXXusr.lha\n" "Wobei XX die Versionsnummer ist." ) ) (set #no-binary-arc (cat "Es konnte kein korrektes Archiv mit dem Hauptprogramm gefunden werden.\n" "Besorge Dir eines vom gleichen Ort, wo Du dieses Archiv gefunden hast, und entpacke es in das gleiche Verzeichnis.\n" "Siehe die Datei 'Laplace#?.readme' für genauere Informationen.\n" ) ) (set #destdir-prompt "Wähle das Verzeichnis, wo Laplace installiert werden soll. Eine neue Schublade wird erzeugt.") (set #destdir-help (cat "Eine Schublade 'Laplace' wird ein gewählten Verzeichnis erzeugt, wo alle nötigen Dateien gespeichert werden.\n\n" @askdir-help ) ) (set #icontype-prompt "Wähle die Piktogramm Kollektion aus:") (set #icontype-help @askchoice-help) (set #icontype-std "4 Farben Standart") (set #icontype-mwb "8 Farben MagicWB2") (set #cputype-prompt "Für welchen Prozessor soll Laplace installiert werden?") (set #cputype-help @askchoice-help) (set #lang-prompt "Welche Sprachen sollen installiert werden?") (set #langs-help @askoptions-help) (set #nostartup-prompt "Soll das Start-Fenster abgeschaltet werden?\nSiehe Hilfe.") (set #nostartup-help (cat "Es wurde berichtet, daß das Start-Fenster bei einigen Systemen zu Problemen führt.\n" "Sollte dies bei Deiner Konfiguration der Fall sein, so läßt es sich abschalten.\n\n" "Wenn Du Dir nicht sicher bist, so lasse es erst einmal eingeschaltet und teste es.\n" "In der Anleitung, Sektion 'Bekannte Fehler', ist beschrieben, wie es im nachhinein abgeschaltet werden kann, ohne Laplace neu zu installieren.\n\n" @askbool-help) ) (set #docs-prompt "In welchen Formaten soll die Dokumentation installiert werden?") (set #docs-help (cat "AmigaGuide:\n" " Dies sollte immer installiert werden, da die Online-Hilfe mit diesem Format arbeitet.\n\n" "ASCII:\n" " So kann die Dokumentation mit jedem Textanzeiger (z.B. MuchMore) angezeigt werden.\n\n" "DVI:\n" " So kann die Dokumentation in hoher Qualität ausgedruckt werden. Dazu ist jedoch eine TeX-Installation nötig.\n\n" @askoptions-help ) ) (set #unpack-main "Entpacke Hauptprogram...") (set #unpack-arexx "Entpacke ARexx Skripte...") (set #unpack-cat "Entpacke Kataloge...") (set #unpack-docs "Entpacke Dokumentation...") (set #unpack-fonts "Entpacke Schriftarten...") (set #unpack-libs "Entpacke Bibliotheken...") (set #unpack-include "Entpacke Include-Dateien...") (set #unpack-presets "Entpacke Einstellungen...") (set #unpack-projects "Entpacke Projekte...") (set #unpack-icons "Entpacke Piktogramme...") (set #unpack-tools "Entpacke Extras...") (set #unpack-buttons "Entpacke Knöpfe...") (set #unpack-images "Entpacke Bilder...") (set #unpack-prefs "Entpacke Konfiguration...") (set #unpack-postscript "Entpacke PostScript-Dateien...") (set #unpack-error "Kann '%s' nicht entpacken.\nDOS Fehlerkode %ld.") (set #copy-icons "Kopiere Piktogramme...") (set #copy-more "Kopiere Dokumentanzeiger...") (set #deldir-prompt "Wähle das Verzeichnis, wo Laplace installiert ist.") (set #deldir-help @askdir-help) (set #deinstall-finish "Laplace wurde aus dem Verzeichnis '%s' gelöscht.\n\nSchade, daß Laplace Dir nicht gefallen hat ;-(") (set #deinstall-working "Laplace wird gelöscht...") (set #deinstall-notfound "Laplace befindet sich nicht im gewählten Verzeichnis.") (set #confirm-prompt (cat "Soll Laplace wirklich gelöscht werden?\n" "Die Daten gehen unwiederbringlich verloren!" ) ) (set #confirm-help @askbool-help) (set #parts-prompt "Welche Programmteile sollen installiert werden?") (set #parts-help (cat "Hauptprogramm:\n" " Laplace, was sonst...\n\n" "Dokumentation:\n" " Programmdokumentation in AmigaGuide und ASCII...\n\n" "Kataloge:\n" " Katalogdateien, um das Hauptprogramm an die gewählte Sprache anzupassen.\n\n" "Standartpiktogramme:\n" " Piktogramme für ARexx-Skripte, Include-Dateien und Projekte.\n\n" "Standartschriftarten:\n" " Du kannst eine eigene Schriftart einstellen, falls Du jedoch griechische Symbole nutzen willst, mußt Du diesen Teil installieren.\n\n" "Beispiel ARexx-Skripte:\n" " einige Beispiel-Skripte, die die Möglichkeiten der ARexx-Schnittstelle zeigen sollen.\n\n" "Include-Dateien:\n" " Bibliotheken mit externen Funktionen.\n\n" "Standarteinstellungen:\n" " einige Einstellungsdateien..\n\n" "Beipielprojekte:\n" " einige Projekte, die die Fähigkeiten von Laplace demonstrieren sollen.\n\n" "Extras:\n" " Ein paar Hilfsprogramme, u.a. ein Skript, um die DVI Anleitung auszudrucken.\n\n" "Knöpfe:\n" " Bilder für die Knopfleiste.\n\n" "Bilder:\n" " Sonstige Bilder.\n\n" "Konfiguration:\n" " Konfigurationsdateien für Menüs, Knopfleiste und Tastaturbelegung.\n\n" @askoptions-help ) ) (set #parts-main "Hauptprogramm") (set #parts-docs "Dokumentaion") (set #parts-cats "Kataloge") (set #parts-icons "Standartpiktogramme") (set #parts-fonts "Standartschriftarten") (set #parts-arexx "Beipiels ARexx-Skripte") (set #parts-include "Include Dateien") (set #parts-presets "Standarteinstellungen") (set #parts-projects "Beispielprojekte") (set #parts-tools "Extras") (set #parts-buttons "Knöpfe") (set #parts-images "Bilder") (set #parts-prefs "Preferences") (set #del-obsolete "Lösche veraltete Dateien...") (set #backups-prompt "Soll ich Sicherheitskopien der alten Dateien anlegen?") (set #backups-help (cat "Die Dateien aus 'Include', 'Presets', 'ARexx', 'Projects' werden jeweils mit der Endung '.old' kopiert, damit sie nicht von neuen Versionen überschrieben werden.\n" @askbool-help ) ) (set #make-backups "Erstelle Sicherheitskopien...") (set #mf-inputs-prompt "Wohin sollen die MetaFont Dateien kopiert werden?") (set #mf-inputs-help (cat "Um die DVI Version der Anleitung anzuzeigen, benötigst Du eine spezielle Schriftart.\n" "Damit MetaFont die nötigen Dateien finden kann, müssen diese in das entsprechende Verzeichnis kopiert werden, z.B. 'MF:inputs/'.\n" @askdir-help ) ) (set #tex-fonts-prompt "Wohin sollen die .tfm Dateien kopiert werden?") (set #tex-fonts-help (cat "Um die DVI Version der Anleitung anzuzeigen, benötigst Du eine spezielle Schriftart.\n" "Damit ShowDVI die nötigen Dateien finden kann, müssen diese in das entsprechende Verzeichnis kopiert werden, z.B. 'TeX:fonts/tfm'.\n" @askdir-help ) ) (set #copy-error "Kann Datei `%s' nicht kopieren.") (set #makedir-error "Kann Verzeichnis `%s' nicht erzeugen.") (set #unpack-error "Kann Archiev `%s' nicht enpacken.") (set #errormsg-cause "Fehlerursache") (set #errormsg-quest "Soll das Skript weiter geführt werden?\n(Siehe `Hilfe' für weiter Infos)") (set #errormsg-proceed "Weiter!") (set #errormsg-cancel "Abbruch!") (set #errormsg-help (cat "Ein ernsthafter Fehler während der Installation ist aufgetreten.\n" "Du kannst mit dem Skript fortfahren, eventuell läuft alles doch noch gut....\n" "Bitte benachrichtige mich über den Fehler!!\n\n" @askbool-help ) ) (set #trap-error-1 "Benutzerabbruch") (set #trap-error-2 "Speicherplatzmangel") (set #trap-error-3 "Skript-Fehler") (set #trap-error-4 "DOS-Fehler Nr. ") (set #trap-error-5 "Falsche Parameter") ;-2- ) (if (= @language "pladd") ( (abort "not implemented") ) ( ;-1- "english" (set #lhapath-prompt "Lha is required! Where can I find it?") (set #lhapath-help (cat "Lha is needed to perform the installation, " "but I could not be found in your C: directory.\n" "Please enter the complete path, where I can find it.\n" "\n" @askfile-help ) ) (set #welcome "Welcome to the installation of Laplace.") (set #mode-prompt "Which action should be performed?") (set #mode-help @askchoice-help) (set #mode-install "install Laplace") (set #modeupdate-prompt (cat "Which action should be performed?\n" "Laplace V%s is already installed at %s." ) ) (set #modeupdate-help @askchoice-help) (set #mode-update "update Laplace") (set #mode-install "install Laplace") (set #mode-deinstall "remove Laplace") (set #share-info (cat "If you like this program, please send me a e-mail or postcard.\n" "\n" "e-mail:\n" "bstegema@ix.urz.uni-heidelberg.de\n" "\n" "s-mail:\n" "Benjamin Stegemann\n" "Emmertsgrundpassage 1\n" "69126 Heidelberg\n" "Germany" ) ) (set #wrongversion (cat "This script need the installer V42.9 or better. " "It is provided in the Laplace/Tools directory and should be used. " "If you have a tool like ToolAlias installed, use this version as your standart." ) ) (set #wrongos (cat "Laplace requires OS V39 or better.\n" "You have V%ld.%ld installed. Sorry." ) ) (set #wrongmui (cat "Laplace requires MUI V13 or better.\n" "You have V%ld.%ld installed. Sorry.\n\n" "MUI can be found in Aminet:\n" "dev/gui/muiXXusr.lha\n" "where XX is the version number." ) ) (set #nomui (cat "Laplace requires MUI V13 or better.\n" "Currently MUI is not installed. Sorry.\n\n" "MUI can be found in Aminet:\n" "dev/gui/muiXXusr.lha\n" "where XX is the version number." ) ) (set #no-binary-arc (cat "There's no valid archive containing the main program of Laplace.\n" "Get one from the same location, where you found this archive, an depack it into the same directory.\n" "Look at the file 'Laplace#?.readme' for more information.\n" ) ) (set #destdir-prompt "Select the directory where Laplace should be installed. A new drawer will be created.") (set #destdir-help (cat "A drawer called 'Laplace' will be created in the selected directory, where all files are stored.\n\n" @askdir-help ) ) (set #icontype-prompt "Select the icon collection you want to use:") (set #icontype-help @askchoice-help) (set #icontype-std "4 color standart") (set #icontype-mwb "8 color MagicWB2") (set #cputype-prompt "Select your processor version?") (set #cputype-help @askchoice-help) (set #langs-prompt "Which languages should be installed?") (set #langs-help @askoptions-help) (set #docs-prompt "Which formats for the documentation should be installed?") (set #docs-help (cat "AmigaGuide:\n" " You should always install this, because the online-help need this format.\n\n" "ASCII:\n" " With this format the documentation can be shown with every textdisplayer (e.g. MuchMore).\n\n" "DVI:\n" " You can use this to print the documentation in high quality. But you need a TeX-installation for this.\n\n" @askoptions-help ) ) (set #nostartup-prompt "Disable the startup-window?\nSee help.") (set #nostartup-help (cat "It has been reported that the startup-window causes some problems on some systems.\n" "If this is the case for your configuration, you can disable it.\n\n" "If you are not sure, leave the startup-window enabled and test it.\n" "In the manual, section 'Known bugs', I expain, how to disable the startup-window, without reinstallung Laplace.\n\n" @askbool-help) ) (set #unpack-main "Decrunching main program...") (set #unpack-arexx "Decrunching ARexx scripts...") (set #unpack-cat "Decrunching catalogs...") (set #unpack-docs "Decrunching documentation...") (set #unpack-fonts "Decrunching fonts...") (set #unpack-libs "Decrunching libraries...") (set #unpack-include "Decrunching include files...") (set #unpack-presets "Decrunching presets...") (set #unpack-projects "Decrunching projects...") (set #unpack-icons "Decrunching icons...") (set #unpack-tools "Decrunching extras...") (set #unpack-buttons "Decrunching buttons...") (set #unpack-images "Decrunching images...") (set #unpack-prefs "Decrunching prefs...") (set #unpack-postscript "Decrunching PostScript files...") (set #unpack-error "Unable to unpack '%s'.\nDOS error code %ld.") (set #copy-icons "Copying icons...") (set #copy-more "Copying text viewer...") (set #deldir-prompt "Select the drawer where Laplace is installed.") (set #deldir-help @askdir-help) (set #deinstall-finish "Laplace has been removed from '%s'.\n\nToo bad that you didn't like Laplace ;-(") (set #deinstall-working "Laplace is being erased...") (set #deinstall-notfound "Laplace can't be found in the selected drawer.") (set #confirm-prompt (cat "Do you really want to remove Laplace?\n" "All files are lost forever!!" ) ) (set #confirm-help @askbool-help) (set #parts-prompt "Which packages should be installed?") (set #parts-help (cat "main program:\n" " Laplace itself...\n\n" "documentation:\n" " docs in AmigaGuide and ASCII...\n\n" "catalogs:\n" " catalogs to adjust the main program to the selected language.\n\n" "default icons:\n" " default icons for ARexx scripts, include files and projects.\n\n" "default fonts:\n" " you may use your own font, but if you want to have greek, symbols you must install this package.\n\n" "example ARexx scripts:\n" " some scripts to show the functions of the ARexx port.\n\n" "include files:\n" " libraries containing external functions.\n\n" "default presets:\n" " some preset files..\n\n" "example projects:\n" " some projects to demonstrate the abilities of Laplace.\n\n" "extras:\n" " some extra programs, among other things a script to print the DVI manual\n\n" "buttons:\n" " button images for the toolbar\n\n" "images:\n" " misc images\n\n" "prefs:\n" " configuration for menus, toolbar and keyboard\n\n" @askoptions-help ) ) (set #parts-icons "default icons") (set #parts-main "main program") (set #parts-docs "documentation") (set #parts-cats "catalogs") (set #parts-fonts "default fonts") (set #parts-arexx "example ARexx scripts") (set #parts-include "include files") (set #parts-presets "default presets") (set #parts-projects "example projects") (set #parts-tools "extras") (set #parts-buttons "buttons") (set #parts-images "images") (set #parts-prefs "prefs") (set #del-obsolete "Deleting obsolete files...") (set #backups-prompt "Should I create backups of your old files?") (set #backups-help (cat "All files from 'Include', 'Presets', 'ARexx', 'Projects' are copied with a suffix '.old' to prevent them from being overwritten.\n" @askbool-help ) ) (set #make-backups "Creating backups...") (set #mf-inputs-prompt "Where should I place the MetaFont files?") (set #mf-inputs-help (cat "To display the DVI version of the manual, you need a special font.\n" "MetaFont needs the files in a directory where it can find them, e.g. 'MF:inputs/'.\n" @askdir-help ) ) (set #tex-fonts-prompt "Where should I place the .tfm files?") (set #tex-fonts-help (cat "To display the DVI version of the manual, you need a special font.\n" "ShowDVI needs the files in a directory where it can find them, e.g. 'TeX:fonts/tfm/'.\n" @askdir-help ) ) (set #copy-error "Unable to copy file `%s'.") (set #makedir-error "Unable to create directory `%s'.") (set #unpack-error "Unable to unpack archive `%s'.") (set #unpack-error-text "Unable to unpack archive `%s'.\nLha returned code %ld.\nDOS error code %ld.\n\nDo you want to continue the script?\n(See help for more info)") (set #errormsg-cause "Errorcause") (set #errormsg-quest "Do you want to continue the script?\n(See help for more info)") (set #errormsg-proceed "Proceed!") (set #errormsg-cancel "Cancel!") (set #errormsg-help (cat "Some serious error during the installation has happened.\n" "You can continue the skript, if you are lucky, everything is ok....\n" "Please report me about the error!!\n\n" @askbool-help ) ) (set #trap-error-1 "Userbreak") (set #trap-error-2 "Out of memory") (set #trap-error-3 "Error in installation script") (set #trap-error-4 "DOS-error code #") (set #trap-error-5 "Wrong Parameters") ;-2- ) ) ) ;-2- ;-1- "P_GOODBYE" (procedure P_GOODBYE ; (run "Data/Demon/LaplaceEvoke EXIT" (safe)) (exit) ) ;-2- ;-1- "P_ERRORMSG" (procedure P_ERRORMSG #errormsg-text (textfile (dest "Installer-Errortext") (append ("%s\n%s: %s\n\n%s\n\n" #errormsg-text #errormsg-cause (select #error "" #trap-error-1 #trap-error-2 #trap-error-3 (cat #trap-error-4 @ioerr) #trap-error-5 ) #errormsg-quest ) ) ) (if (= 0 (askbool (prompt ("%s\n%s: %s\n\n%s" #errormsg-text #errormsg-cause (select #error "" #trap-error-1 #trap-error-2 #trap-error-3 (cat #trap-error-4 @ioerr) #trap-error-5 ) #errormsg-quest ) ) (help #errormsg-help) (choices #errormsg-proceed #errormsg-cancel) ) ) (abort "Bye!") ) ) ;-2- ;-1- "P_UNPACK" (procedure P_UNPACK #unpack-msg #unpack-src #unpack-dest (debug "unpack:" #unpack-src "to" #unpack-dest) (working #unpack-msg) (set #error (trap $ffffffff ( (set #unpack-rc (run ("%s >lha_output x \"%s\" \"%s\"" #lhapath #unpack-src #unpack-dest))) (if (> #unpack-rc 0) ( (textfile (dest "Installer-Errortext") (append (#unpack-error-text #unpack-src #unpack-rc @ioerr ) ) (append "\n\n") (include "lha_output") ) (if (= 0 (askbool (prompt (#unpack-error-text #unpack-src #unpack-rc @ioerr ) ) (help #errormsg-help) (choices #errormsg-proceed #errormsg-cancel) ) ) (abort "Bye!") ) ) ) ) ) ) (if #error (P_ERRORMSG (#unpack-error #unpack-src)) ) ) ;-2- ;-1- "P_COPYPATTERN" (procedure P_COPYPATTERN #copyas-src #copyas-pattern #copyas-dest (debug "copy pattern:" #copyas-src "/" #copyas-pattern "to" #copyas-dest) (set #error (trap $ffffffff (copyfiles (source #copyas-src) (pattern #copyas-pattern) (dest #copyas-dest) (nogauge) ) ) ) (if #error (P_ERRORMSG (#copy-error (tackon #copyas-src #copyas-pattern))) ) ) ;-2- ;-1- "P_COPYAS" (procedure P_COPYAS #copyas-src #copyas-dest #copyas-name (debug "copy:" #copyas-src "to" #copyas-dest "as" #copyas-name) (set #error (trap $ffffffff (copyfiles (source #copyas-src) (dest #copyas-dest) (newname #copyas-name) (nogauge) ) ) ) (if #error (P_ERRORMSG (#copy-error #copyas-src)) ) ) ;-2- ;-1- "P_COPYICON" (procedure P_COPYICON #copyas-src #copyas-dest #copyas-name (debug "copyicon:" #copyas-src "to" #copyas-dest "as" #copyas-name) (set #error (trap $ffffffff (copyfiles (source #copyas-src) (dest #copyas-dest) (newname #copyas-name) (noposition) (nogauge) ) ) ) (if #error (P_ERRORMSG (#copy-error #copyas-src)) ) ) ;-2- ;-1- "P_BACKUPDIR" (procedure P_BACKUPDIR #backupdir-src #backupdir-dest (debug "backupdir:" #backupdir-src "to" #backupdir-dest) (if (exists #backupdir-src) (foreach #backupdir-src "~(#?.(info|old))" (P_COPYAS (tackon #backupdir-src @each-name) #backupdir-dest (cat @each-name ".old") ) ) ) ) ;-2- ;-1- "P_MAKEDIR" (procedure P_MAKEDIR #makedir-name (debug "makedir:" #makedir-name) (set #error (trap $ffffffff (makedir #makedir-name) ) ) (if #error (P_ERRORMSG (#makedir-error #makedir-name)) ) ) ;-2- ;-1- "P_INSTALL" ;-1- "P_INSTALL_CHECK" (procedure P_INSTALL_CHECK ; We can't handle this script without Installer 42.9 or better! (if (< @installer-version 2752521) (abort #wrongversion) ) ; check OS (set #os-version (getversion)) (if (< #os-version 2555904) (abort (#wrongos (shiftright #os-version 16) (bitand #os-version 65535))) ) ; check MUI (if (exists "MUI:Libs/muimaster.library" (noreq)) (set #mui-version (getversion "MUI:Libs/muimaster.library")) (set #mui-version 0) ) (if (< #mui-version 851968) (abort (if (= #mui-version 0) #nomui (#wrongmui (shiftright #mui-version 16) (bitand #mui-version 65535)) ) ) ) ; set cpu-default type ; 0 : 000 nfp ; 1 : 020 nfp ; 2 : 020 881 ; 3 : 040 (set #cpu-default (if (patmatch "(68000|68010)" (database "cpu")) 0 (if (patmatch "68040" (database "cpu")) 3 (if (database "fpu" "NOFPU") 1 2 ) ) ) ) ; check for a binary archive (if (and (= #cpu-default 3) (not (exists "Data/Main_040.lha"))) (set #cpu-default 2) ) (if (and (= #cpu-default 2) (not (exists "Data/Main_020fp.lha"))) (set #cpu-default 1) ) (if (and (= #cpu-default 1) (not (exists "Data/Main_020.lha"))) (set #cpu-default 0) ) (if (and (= #cpu-default 0) (not (exists "Data/Main_000.lha"))) (abort #no-binary-arc) ) ) ;-2- ;-1- "P_INSTALL_ASK" (procedure P_INSTALL_ASK ; get path for Lha (set #lhapath "c:Lha") (while (<> (exists #lhapath (noreq)) 1) ( (if (= @user-level 0) (abort "Since I don't know how to force the Installer to ask you for the path of Lha, I must ask you not to use the Novice mode..\n\nSorry for the inconvenience.") ) (set #lhapath (askfile (prompt #lhapath-prompt) (help #lhapath-help) (default #lhapath) ) ) ) ) ; get destination dir (set #dest (askdir (prompt #destdir-prompt) (help #destdir-help) (default @default-dest) ) ) (set @default-dest #dest) ; get icons type (set #icon-type (askchoice (prompt #icontype-prompt) (help #icontype-help) (choices #icontype-std #icontype-mwb) (default (if (= (getenv "MagicWB") "") 0 1 ) ) ) ) ; get cpu and fpu type ;(set #cpu-type 020) ;(set #fpu-type nfp) ;(set #n 0) ; ;(foreach "Data/" "Main_???_???.lha" ; ( ; (symbolset ("#main-path-%ld" #n) @each-name) ; (symbolset ("#cpu-type-%ld" #n) (substr @each-name 5 3)) ; (symbolset ("#fpu-type-%ld" #n) (substr @each-name 9 3)) ; (set #cputype-choices ("MC68%s %s" (symbolval ("#cpu-type-%ld" #n)) (symbolval ("#fpu-type-%ld" #n)))) ; (set #n (+ #n 1)) ; ) ;) (set #cpu-sel (askchoice (prompt #cputype-prompt) (help #cputype-help) (choices (if (exists "Data/Main_000.lha") "68000" "") (if (exists "Data/Main_020.lha") "68020" "") (if (exists "Data/Main_020fp.lha") "68020 + 68881" "") (if (exists "Data/Main_040.lha") "68040" "") ) (default #cpu-default) ) ) (set #cpu-type (select #cpu-sel "000" "020" "020fp" "040")) (debug "cpu-sel = " #cpu-sel) (debug "cpu-type = " #cpu-type) ; select parts ;(set #parts ; (askoptions ; (prompt #parts-prompt) ; (help #parts-help) ; (choices ; #parts-main ; #parts-docs ; #parts-cats ; #parts-icons ; #parts-fonts ; #parts-arexx ; #parts-include ; #parts-presets ; #parts-projects ; #parts-tools ; #parts-buttons ; #parts-images ; #parts-prefs ; ) ; ) ;) ;(if (in #parts 1) ; ( ; ; get languages ; (set #langs ; (askoptions ; (prompt #langs-prompt) ; (help #langs-help) ; (choices "english" "deutsch") ; ) ; ) ; ; ; get doc types ; (set #docs ; (askoptions ; (prompt #docs-prompt) ; (help #docs-help) ; (choices "AmigaGuide" "ASCII" "DVI") ; ) ; ) ; ; ; ask for tex paths ; (if (in #docs 2) ; ( ; (set #mf-inputs "MF:inputs/") ; ; (while (<> (exists #mf-inputs (noreq)) 2) ; ( ; (if (= @user-level 0) ; (abort "Since I don't know how to force the Installer to ask you for the path, I must ask you not to use the Novice mode..\n\nSorry for the inconvenience.") ; ) ; (set #mf-inputs ; (askdir ; (prompt #mf-inputs-prompt) ; (help #mf-inputs-help) ; (default #mf-inputs) ; (newpath) ; ) ; ) ; ) ; ) ; ; (set #tex-fonts "TeX:fonts/tfm/") ; ; (while (<> (exists #tex-fonts (noreq)) 2) ; ( ; (if (= @user-level 0) ; (abort "Since I don't know how to force the Installer to ask you for the path, I must ask you not to use the Novice mode..\n\nSorry for the inconvenience.") ; ) ; (set #tex-fonts ; (askdir ; (prompt #tex-fonts-prompt) ; (help #tex-fonts-help) ; (default #tex-fonts) ; (newpath) ; ) ; ) ; ) ; ) ; ) ; ) ; ) ;) (set #backups (if (exists "ENVARC:Laplace") (askbool (prompt #backups-prompt) (help #backups-help) ) 0 ) ) (set #start-options "") (if (>= @user-level 2) (if (askbool (prompt #nostartup-prompt) (help #nostartup-help) (default 0) ) (set #start-options "-q") ) ) ;(set #start-options (cat #start-options " --logfile T:Laplace.log")) ) ;-2- ;-1- "P_INSTALL_PERFORM" (procedure P_INSTALL_PERFORM (onerror ( (delete "T:Laplace_temp" (all)) (delete (tackon #dest "Laplace") (all)) (delete (tackon #dest "Laplace.info")) ) ) (P_UNPACK #unpack-icons (select #icon-type "Data/Icons_std.lha" "Data/Icons_mwb.lha" ) "T:Laplace_temp/" ) (P_MAKEDIR (tackon #dest "Laplace")) (P_MAKEDIR (tackon #dest "Laplace/bin")) (P_MAKEDIR (tackon #dest "Laplace/Docs")) (P_MAKEDIR (tackon #dest "Laplace/Docs/english")) (P_MAKEDIR (tackon #dest "Laplace/Data")) (P_MAKEDIR (tackon #dest "Laplace/Data/Libs")) (P_MAKEDIR (tackon #dest "Laplace/Data/Intro")) (P_MAKEDIR (tackon #dest "Laplace/Data/Tables")) (P_MAKEDIR (tackon #dest "Laplace/Data/Fonts")) (P_MAKEDIR (tackon #dest "Laplace/Data/Icons")) (P_MAKEDIR (tackon #dest "Laplace/Data/Catalogs")) (P_MAKEDIR (tackon #dest "Laplace/Data/PostScript")) (P_MAKEDIR (tackon #dest "Laplace/Data/PostScript/AFM")) ;(P_MAKEDIR (tackon #dest "Laplace/Data/ARexx")) (P_MAKEDIR (tackon #dest "Laplace/Data/Include")) (P_MAKEDIR (tackon #dest "Laplace/Data/Buttons")) (P_MAKEDIR (tackon #dest "Laplace/Data/Prefs")) (P_MAKEDIR (tackon #dest "Laplace/Data/Prefs/Presets")) (P_MAKEDIR (tackon #dest "Laplace/Data/Prefs/Plotter")) (P_MAKEDIR (tackon #dest "Laplace/Data/Prefs/Printer")) (P_MAKEDIR (tackon #dest "Laplace/Data/Images")) (P_MAKEDIR (tackon #dest "Laplace/Projects")) (P_MAKEDIR (tackon #dest "Laplace/Tools")) (P_MAKEDIR (tackon #dest "Laplace/Modules")) (P_MAKEDIR (tackon #dest "Laplace/Modules/Numeric")) ; backup old files (if (<> #backups 0) ( (working #make-backups) ;(P_BACKUPDIR ; (tackon #dest "Laplace/ARexx") ; (tackon #dest "Laplace/Data/ARexx") ;) ;(P_BACKUPDIR ; (tackon #dest "Laplace/Data/ARexx") ; (tackon #dest "Laplace/Data/ARexx") ;) (P_BACKUPDIR (tackon #dest "Laplace/Include") (tackon #dest "Laplace/Data/Include") ) (P_BACKUPDIR (tackon #dest "Laplace/Data/Include") (tackon #dest "Laplace/Data/Include") ) (P_BACKUPDIR (tackon #dest "Laplace/Projects") (tackon #dest "Laplace/Projects") ) (P_BACKUPDIR (tackon #dest "Laplace/Prefs") (tackon #dest "Laplace/Prefs") ) ;(P_BACKUPDIR ; (tackon #dest "Laplace/Presets") ; (tackon #dest "Laplace/Data/Presets") ;) ;(P_BACKUPDIR ; (tackon #dest "Laplace/Data/Presets") ; (tackon #dest "Laplace/Data/Presets") ;) ) ) ; delete obsolete files (working #del-obsolete) (delete (tackon #dest "Laplace/Laplace.image")) (delete (tackon #dest "Laplace/Laplace.image_mwb")) (delete (tackon #dest "Laplace/Laplace.image2")) (delete (tackon #dest "Laplace/Laplace.sample")) (delete (tackon #dest "Laplace/Libs") (all)) (delete (tackon #dest "Laplace/Libs.info")) (delete (tackon #dest "Laplace/Fonts") (all)) (delete (tackon #dest "Laplace/Fonts.info")) (delete (tackon #dest "Laplace/Presets") (all)) (delete (tackon #dest "Laplace/Presets.info")) (delete (tackon #dest "Laplace/Icons") (all)) (delete (tackon #dest "Laplace/Icons.info")) (delete (tackon #dest "Laplace/Include") (all)) (delete (tackon #dest "Laplace/Include.info")) (delete (tackon #dest "Laplace/ARexx") (all)) (delete (tackon #dest "Laplace/ARexx.info")) (delete (tackon #dest "Laplace/Catalogs") (all)) (delete (tackon #dest "Laplace/Catalogs.info")) (delete (tackon #dest "Laplace/Data/Intro/#?") (all)) (delete (tackon #dest "Laplace/Data/Tables/#?") (all)) (delete (tackon #dest "Laplace/Data/Fonts/#?") (all)) (delete (tackon #dest "Laplace/Data/Libs/#?") (all)) (delete (tackon #dest "Laplace/Data/Catalogs/#?") (all)) (delete (tackon #dest "Laplace/Data/Images/#?") (all)) (delete (tackon #dest "Laplace/Data/Prefs/#?") (all)) (delete (tackon #dest "Laplace/Data/PostScript/#?") (all)) (delete (tackon #dest "Laplace/Data/Modules/#?") (all)) (working #copy-icons) (P_COPYAS "T:Laplace_temp/Laplace.info" #dest "Laplace.info" ) (P_COPYPATTERN "T:Laplace_temp/Laplace" "#?.info" (tackon #dest "Laplace") ) (P_COPYPATTERN "T:Laplace_temp/Laplace/Data" "#?.info" (tackon #dest "Laplace/Data") ) ;(working #copy-more) ; ;(P_COPYAS ; "Tools/MuchMore" ; (tackon #dest "Laplace/c") ; "MuchMore" ;) (P_UNPACK #unpack-main ("Data/Main_%s.lha" #cpu-type) (tackon #dest "Laplace/")) (textfile (dest (tackon #dest "Laplace/Laplace")) (append "Stack 300000\n") (append "set LAPLACEHOME `cd`\n") (append ("bin/Laplace %s\n" #start-options)) ) (P_UNPACK #unpack-libs "Data/Libs.lha" (tackon #dest "Laplace/Data/Libs/")) (P_UNPACK #unpack-cat "Data/Catalogs.lha" (tackon #dest "Laplace/Data/Catalogs/")) (P_UNPACK #unpack-fonts "Data/Fonts.lha" (tackon #dest "Laplace/Data/Fonts/")) (P_UNPACK #unpack-include "Data/Include.lha" (tackon #dest "Laplace/Data/Include/")) (P_UNPACK #unpack-intro "Data/Intro.lha" (tackon #dest "Laplace/Data/Intro/")) (P_UNPACK #unpack-buttons "Data/Buttons.lha" (tackon #dest "Laplace/Data/Buttons/")) (working #prep-images) (foreach (tackon #dest "Laplace/Data/Buttons/") "~(#?.#?)" ( (debug ("Tools/pguiPrepImage >\"%s.dat\" \"%s\"" (tackon #dest ("Laplace/Data/Images/%s" @each-name)) (tackon #dest ("Laplace/Data/Images/%s" @each-name)))) (run ("Tools/pguiPrepImage >\"%s.dat\" \"%s\"" (tackon #dest ("Laplace/Data/Buttons/%s" @each-name)) (tackon #dest ("Laplace/Data/Buttons/%s" @each-name)))) ) ) (P_UNPACK #unpack-images "Data/Images.lha" (tackon #dest "Laplace/Data/Images/")) (working #prep-images) (foreach (tackon #dest "Laplace/Data/Images/") "~(#?.#?)" ( (debug ("Tools/pguiPrepImage >\"%s.dat\" \"%s\"" (tackon #dest ("Laplace/Data/Images/%s" @each-name)) (tackon #dest ("Laplace/Data/Images/%s" @each-name)))) (run ("Tools/pguiPrepImage >\"%s.dat\" \"%s\"" (tackon #dest ("Laplace/Data/Images/%s" @each-name)) (tackon #dest ("Laplace/Data/Images/%s" @each-name)))) ) ) (P_UNPACK #unpack-postscript "Data/PostScript.lha" (tackon #dest "Laplace/Data/PostScript/")) (P_UNPACK #unpack-prefs "Data/Prefs.lha" (tackon #dest "Laplace/Data/Prefs/")) (P_UNPACK #unpack-tables "Data/Tables.lha" (tackon #dest "Laplace/Data/Tables/")) (P_UNPACK #unpack-docs "Data/Docs_english.lha" (tackon #dest "Laplace/Docs/english/")) (P_UNPACK #unpack-docs "Data/Docs_english_guide.lha" (tackon #dest "Laplace/Docs/english/")) (P_UNPACK #unpack-docs "Data/Docs_deutsch.lha" (tackon #dest "Laplace/Docs/deutsch/")) (P_UNPACK #unpack-docs "Data/Docs_deutsch_guide.lha" (tackon #dest "Laplace/Docs/deutsch/")) (P_UNPACK #unpack-projects "Data/Projects.lha" (tackon #dest "Laplace/Projects/")) (P_UNPACK #unpack-tools "Data/Tools.lha" (tackon #dest "Laplace/Tools/")) (working #copy-icons) ;(P_COPYPATTERN ; "T:Laplace_temp/Docs/" ; "(History|Readme.mui|Copyright).info" ; (tackon #dest "Laplace/Docs") ;) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english.info" (tackon #dest "Laplace/Docs") "english.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/Manual.guide.info" (tackon #dest "Laplace/Docs/english") "Manual.guide.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/BugReport.info" (tackon #dest "Laplace/Docs/english") "BugReport.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/Registration.info" (tackon #dest "Laplace/Docs/english") "Registration.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english.info" (tackon #dest "Laplace/Docs") "deutsch.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/Manual.guide.info" (tackon #dest "Laplace/Docs/deutsch") "Anleitung.guide.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/BugReport.info" (tackon #dest "Laplace/Docs/deutsch") "Fehlermeldung.info" ) (P_COPYICON "T:Laplace_temp/Laplace/Docs/english/Registration.info" (tackon #dest "Laplace/Docs/deutsch") "Registrierung.info" ) (P_COPYPATTERN "T:Laplace_temp/Laplace/Data/Icons" "#?" (tackon #dest "Laplace/Data/Icons") ) (foreach (tackon #dest "Laplace/Data/Include") "~(#?.info)" (P_COPYICON "T:Laplace_temp/Laplace/Data/Icons/def_Include.info" (tackon #dest "Laplace/Data/Include") (cat @each-name ".info") ) ) (foreach (tackon #dest "Laplace/Projects") "~(#?.info)" (P_COPYICON "T:Laplace_temp/Laplace/Data/Icons/def_Project.info" (tackon #dest "Laplace/Projects") (cat @each-name ".info") ) ) ;; main part ;(if (in #parts 0) ; ( ; (P_UNPACK #unpack-main "Data/Main.lha" (tackon #dest "Laplace/")) ; (P_UNPACK #unpack-libs "Data/Libs.lha" (tackon #dest "Laplace/Data/Libs/")) ; ) ;) ; ;; docs ;(if (in #parts 1) ; ( ; (P_UNPACK #unpack-docs "Data/Docs.lha" (tackon #dest "Laplace/Docs/")) ; ; (working #copy-icons) ; (P_COPYPATTERN ; "T:Laplace_temp/Docs/" ; "(History|Readme.mui|Copyright).info" ; (tackon #dest "Laplace/Docs") ; ) ; ; (if (in #langs 0) ; ( ; (P_MAKEDIR (tackon #dest "Laplace/Docs/english")) ; (P_COPYAS ; "Data/Docs_english_files" ; (tackon #dest "Laplace/Docs/english") ; "Files" ; ) ; ; (working #copy-icons) ; (P_COPYICON ; "T:Laplace_temp/Extra/Drawer2.info" ; (tackon #dest "Laplace/Docs") ; "english.info" ; ) ; ; (if (in #docs 0) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_english_guide.lha" (tackon #dest "Laplace/Docs/english/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/ARexx.info" (tackon #dest "Laplace/Docs/english") "ARexx.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Functions.info" (tackon #dest "Laplace/Docs/english") "Functions.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.info" (tackon #dest "Laplace/Docs/english") "Manual.info") ; ) ; ) ; ; (if (in #docs 1) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_english_doc.lha" (tackon #dest "Laplace/Docs/english/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/ARexx.doc.info" (tackon #dest "Laplace/Docs/english") "ARexx.doc.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Functions.doc.info" (tackon #dest "Laplace/Docs/english") "Functions.doc.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.doc.info" (tackon #dest "Laplace/Docs/english") "Manual.doc.info") ; ) ; ) ; ; (if (in #docs 2) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_english_dvi.lha" (tackon #dest "Laplace/Docs/english/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.dvi.info" (tackon #dest "Laplace/Docs/english") "Manual.dvi.info") ; ) ; ) ; ) ; ) ; (if (in #langs 1) ; ( ; (P_MAKEDIR (tackon #dest "Laplace/Docs/deutsch")) ; (P_COPYAS ; "Data/Docs_deutsch_files" ; (tackon #dest "Laplace/Docs/deutsch") ; "Files" ; ) ; ; (working #copy-icons) ; (P_COPYICON ; "T:Laplace_temp/Extra/Drawer2.info" ; (tackon #dest "Laplace/Docs") ; "deutsch.info" ; ) ; ; (if (in #docs 0) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_deutsch_guide.lha" (tackon #dest "Laplace/Docs/deutsch/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/ARexx.info" (tackon #dest "Laplace/Docs/deutsch") "ARexx.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Functions.info" (tackon #dest "Laplace/Docs/deutsch") "Funktionen.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.info" (tackon #dest "Laplace/Docs/deutsch") "Anleitung.info") ; ) ; ) ; ; (if (in #docs 1) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_deutsch_doc.lha" (tackon #dest "Laplace/Docs/deutsch/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/ARexx.doc.info" (tackon #dest "Laplace/Docs/deutsch") "ARexx.doc.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Functions.doc.info" (tackon #dest "Laplace/Docs/deutsch") "Funktionen.doc.info") ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.doc.info" (tackon #dest "Laplace/Docs/deutsch") "Anleitung.doc.info") ; ) ; ) ; ; (if (in #docs 2) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_deutsch_dvi.lha" (tackon #dest "Laplace/Docs/deutsch/")) ; (working #copy-icons) ; (P_COPYAS "T:Laplace_temp/Docs/english/Manual.dvi.info" (tackon #dest "Laplace/Docs/deutsch") "Anleitung.dvi.info") ; ) ; ) ; ) ; ) ; ; (if (in #docs 2) ; ( ; (P_UNPACK #unpack-docs "Data/Docs_Fonts.lha" "T:Laplace_temp/") ; (P_COPYAS "T:Laplace_temp/lapdoc.mf" #mf-inputs "lapdoc.mf") ; (P_COPYAS "T:Laplace_temp/lapdoc.tfm" #tex-fonts "lapdoc.tfm") ; (delete "T:Laplace_temp/lapdoc.mf") ; (delete "T:Laplace_temp/lapdoc.tfm") ; ) ; ) ; ) ;) ; ;; catalogs ;(if (in #parts 2) ; ( ; (if (in #langs 1) ; ( ; (P_MAKEDIR (tackon #dest "Laplace/Data/Catalogs/deutsch")) ; (P_UNPACK #unpack-cat "Data/Catalogs_deutsch.lha" (tackon #dest "Laplace/Data/Catalogs/deutsch/")) ; ) ; ) ; ) ;) ; ;; icons ;(if (in #parts 3) ; (P_COPYPATTERN ; "T:Laplace_temp/Data/Icons" ; "#?" ; (tackon #dest "Laplace/Data/Icons") ; ) ;) ; ;; fonts ;(if (in #parts 4) ; (P_UNPACK #unpack-fonts "Data/Fonts.lha" (tackon #dest "Laplace/Data/Fonts/")) ;) ; ;; arexx scripts ;(if (in #parts 5) ; ( ; (P_UNPACK #unpack-arexx "Data/ARexx.lha" (tackon #dest "Laplace/Data/ARexx/")) ; (working #copy-icons) ; (foreach (tackon #dest "Laplace/Data/ARexx") "~(#?.info)" ; (P_COPYICON ; "T:Laplace_temp/Data/Icons/def_ARexx.info" ; (tackon #dest "Laplace/Data/ARexx") ; (cat @each-name ".info") ; ) ; ) ; ) ;) ; ;; include ;(if (in #parts 6) ; ( ; (P_UNPACK #unpack-include "Data/Include.lha" (tackon #dest "Laplace/Data/Include/")) ; (working #copy-icons) ; (foreach (tackon #dest "Laplace/Data/Include") "~(#?.info)" ; (P_COPYICON ; "T:Laplace_temp/Data/Icons/def_Include.info" ; (tackon #dest "Laplace/Data/Include") ; (cat @each-name ".info") ; ) ; ) ; ) ;) ; ;; presets ;(if (in #parts 7) ; ( ; (P_UNPACK #unpack-presets "Data/Presets.lha" (tackon #dest "Laplace/Data/Presets/")) ; (working #copy-icons) ; (foreach (tackon #dest "Laplace/Data/Presets") "~(#?.info)" ; (P_COPYICON ; "T:Laplace_temp/Data/Icons/def_Preset.info" ; (tackon #dest "Laplace/Data/Presets") ; (cat @each-name ".info") ; ) ; ) ; ) ;) ; ;; projects ;(if (in #parts 8) ; ( ; (P_UNPACK #unpack-projects "Data/Projects.lha" (tackon #dest "Laplace/Projects/")) ; (working #copy-icons) ; (foreach (tackon #dest "Laplace/Projects") "~(#?.info)" ; (P_COPYICON ; "T:Laplace_temp/Data/Icons/def_Project.info" ; (tackon #dest "Laplace/Projects") ; (cat @each-name ".info") ; ) ; ) ; ) ;) ; ;; tools ;(if (in #parts 9) ; ( ; (P_UNPACK #unpack-tools "Data/Tools.lha" (tackon #dest "Laplace/Tools/")) ; (working #copy-icons) ; (P_COPYICON ; "T:Laplace_temp/Tools/PrintManual.info" ; (tackon #dest "Laplace/Tools/") ; "PrintManual.info" ; ) ; ) ;) ; ;; buttons ;(if (in #parts 10) ; ( ; (P_UNPACK #unpack-buttons ; (select #icon-type ; "Data/Buttons_std.lha" ; "Data/Buttons_mwb.lha" ; ) ; (tackon #dest "Laplace/Data/Buttons/") ; ) ; ) ;) ; ;; images ;(if (in #parts 11) ; ( ; (P_UNPACK #unpack-images ; "Data/Images.lha" ; (tackon #dest "Laplace/Data/Images/") ; ) ; ) ;) ; ;; prefs ;(if (in #parts 12) ; ( ; (P_UNPACK #unpack-prefs ; "Data/Prefs.lha" ; (tackon #dest "Laplace/Data/Prefs/") ; ) ; ) ;) (delete "T:Laplace_temp" (all)) ) ;-2- (procedure P_INSTALL (message #share-info (all)) (set @user-level #defuser-level) (welcome #welcome) (P_INSTALL_CHECK) (P_INSTALL_ASK) (P_INSTALL_PERFORM) (run ("Tools/SetConfig PATH=\"%s\" VERSION=0.9" @default-dest)) ; Finito (complete 100) (P_GOODBYE) ) ;-2- ;-1- "P_REMOVE" (procedure P_REMOVE ; get destination dir (set #dest (askdir (prompt #deldir-prompt) (help #deldir-help) (default @default-dest) ) ) (if (= (substr #dest (- (strlen #dest) 8)) "/Laplace") (set #dest (substr #dest 0 (- (strlen #dest) 8))) ) (if (= (substr #dest (- (strlen #dest) 9)) "/Laplace/") (set #dest (substr #dest 0 (- (strlen #dest) 9))) ) (if (= (exists (tackon #dest "Laplace") (noreq)) 2) (if (= (askbool (prompt #confirm-prompt) (help #confirm-help) ) 1 ) ( (working #deinstall-working) (delete (tackon #dest "Laplace") (all)) (delete (tackon #dest "Laplace.info")) (delete "ENVARC:Laplace") (delete "ENV:Laplace") (message (#deinstall-finish #dest)) ) ) (message #deinstall-notfound) ) (P_GOODBYE) ) ;-2- ;-1- "main menu" (complete 0) (onerror ; (run "Data/Demon/LaplaceEvoke EXIT" (safe)) ) ;(run "run >NIL: Data/Demon/LaplaceDemon" (safe)); ;(run "Data/Demon/LaplaceEvoke WAIT 5" (safe)); ;(run "Data/Demon/LaplaceEvoke PLAYMOD Data/Demon/mod.Prelude1DMin" (safe)); ;(run "Data/Demon/LaplaceEvoke SHOWPIC Data/Demon/Welcome" (safe)); (if (exists "ENVARC:Laplace") ( (run "Tools/GetConfig >ENV:Laplace_Version VERSION") (run "Tools/GetConfig >ENV:Laplace_Path PATH") (set @default-dest (getenv "Laplace_Path")) (set #old-version (getenv "Laplace_Version")) (set #defuser-level 0) (select (askchoice (prompt (#modeupdate-prompt #old-version @default-dest)) (help #modeupdate-help) (choices #mode-update #mode-deinstall) (default 0) ) (P_INSTALL) (P_REMOVE) ) ) ( (set #defuser-level 1) (select (askchoice (prompt #mode-prompt) (help #mode-help) (choices #mode-install #mode-deinstall) (default 0) ) (P_INSTALL) (P_REMOVE) ) ) (P_GOODBYE) ) ;-2-